<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>用户管理 - 二手图书交易平台</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet">
</head>
<body class="bg-gray-50 p-6">
    <div class="space-y-6">
        <!-- 页面标题 -->
        <div class="flex justify-between items-center">
            <h1 class="text-2xl font-bold text-gray-900">用户管理</h1>
            <div class="flex space-x-4">
                <button class="bg-blue-600 text-white px-4 py-2 rounded-lg hover:bg-blue-700">
                    <i class="fas fa-download mr-2"></i>导出数据
                </button>
                <button class="bg-green-600 text-white px-4 py-2 rounded-lg hover:bg-green-700">
                    <i class="fas fa-plus mr-2"></i>添加管理员
                </button>
            </div>
        </div>

        <!-- 统计卡片 -->
        <div class="grid grid-cols-4 gap-6">
            <div class="bg-white p-6 rounded-lg shadow">
                <div class="flex justify-between items-start">
                    <div>
                        <p class="text-sm font-medium text-gray-600">待审核用户</p>
                        <p class="text-2xl font-semibold text-gray-900 mt-2">24</p>
                    </div>
                    <div class="p-3 bg-blue-100 rounded-lg">
                        <i class="fas fa-user-clock text-blue-600"></i>
                    </div>
                </div>
                <div class="mt-4">
                    <span class="text-sm text-red-600"><i class="fas fa-arrow-up"></i> 8% 较昨日</span>
                </div>
            </div>
            <div class="bg-white p-6 rounded-lg shadow">
                <div class="flex justify-between items-start">
                    <div>
                        <p class="text-sm font-medium text-gray-600">总用户数</p>
                        <p class="text-2xl font-semibold text-gray-900 mt-2">2,847</p>
                    </div>
                    <div class="p-3 bg-green-100 rounded-lg">
                        <i class="fas fa-users text-green-600"></i>
                    </div>
                </div>
                <div class="mt-4">
                    <span class="text-sm text-green-600"><i class="fas fa-arrow-up"></i> 12% 较上月</span>
                </div>
            </div>
            <div class="bg-white p-6 rounded-lg shadow">
                <div class="flex justify-between items-start">
                    <div>
                        <p class="text-sm font-medium text-gray-600">今日活跃</p>
                        <p class="text-2xl font-semibold text-gray-900 mt-2">486</p>
                    </div>
                    <div class="p-3 bg-purple-100 rounded-lg">
                        <i class="fas fa-chart-line text-purple-600"></i>
                    </div>
                </div>
                <div class="mt-4">
                    <span class="text-sm text-green-600"><i class="fas fa-arrow-up"></i> 3% 较昨日</span>
                </div>
            </div>
            <div class="bg-white p-6 rounded-lg shadow">
                <div class="flex justify-between items-start">
                    <div>
                        <p class="text-sm font-medium text-gray-600">违规用户</p>
                        <p class="text-2xl font-semibold text-gray-900 mt-2">12</p>
                    </div>
                    <div class="p-3 bg-red-100 rounded-lg">
                        <i class="fas fa-user-slash text-red-600"></i>
                    </div>
                </div>
                <div class="mt-4">
                    <span class="text-sm text-red-600"><i class="fas fa-arrow-down"></i> 5% 较上月</span>
                </div>
            </div>
        </div>

        <!-- 用户列表 -->
        <div class="bg-white rounded-lg shadow">
            <!-- 搜索和筛选 -->
            <div class="p-4 border-b border-gray-200">
                <div class="flex justify-between items-center">
                    <div class="flex space-x-4 items-center">
                        <div class="relative">
                            <input type="text" placeholder="搜索用户..." class="pl-10 pr-4 py-2 border rounded-lg w-64">
                            <i class="fas fa-search absolute left-3 top-3 text-gray-400"></i>
                        </div>
                        <select class="border rounded-lg px-4 py-2">
                            <option>所有状态</option>
                            <option>待审核</option>
                            <option>已认证</option>
                            <option>已封禁</option>
                        </select>
                        <select class="border rounded-lg px-4 py-2">
                            <option>所有角色</option>
                            <option>学生</option>
                            <option>教师</option>
                            <option>管理员</option>
                        </select>
                    </div>
                    <div class="flex items-center space-x-4">
                        <button class="text-gray-600 hover:text-gray-900">
                            <i class="fas fa-filter mr-2"></i>高级筛选
                        </button>
                        <button class="text-gray-600 hover:text-gray-900">
                            <i class="fas fa-sync-alt mr-2"></i>刷新
                        </button>
                    </div>
                </div>
            </div>

            <!-- 表格 -->
            <div class="overflow-x-auto">
                <table class="w-full">
                    <thead class="bg-gray-50">
                        <tr>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                用户信息
                            </th>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                角色
                            </th>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                状态
                            </th>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                注册时间
                            </th>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                操作
                            </th>
                        </tr>
                    </thead>
                    <tbody class="bg-white divide-y divide-gray-200">
                        <tr>
                            <td class="px-6 py-4 whitespace-nowrap">
                                <div class="flex items-center">
                                    <div class="h-10 w-10 rounded-full bg-gray-200 flex items-center justify-center">
                                        <i class="fas fa-user text-gray-400"></i>
                                    </div>
                                    <div class="ml-4">
                                        <div class="text-sm font-medium text-gray-900">张三</div>
                                        <div class="text-sm text-gray-500">2020302111</div>
                                    </div>
                                </div>
                            </td>
                            <td class="px-6 py-4 whitespace-nowrap">
                                <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-blue-100 text-blue-800">
                                    学生
                                </span>
                            </td>
                            <td class="px-6 py-4 whitespace-nowrap">
                                <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-yellow-100 text-yellow-800">
                                    待审核
                                </span>
                            </td>
                            <td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">
                                2023-09-01 14:30
                            </td>
                            <td class="px-6 py-4 whitespace-nowrap text-sm font-medium">
                                <a href="#" class="text-blue-600 hover:text-blue-900 mr-4">审核</a>
                                <a href="#" class="text-red-600 hover:text-red-900">封禁</a>
                            </td>
                        </tr>
                        <!-- 更多用户行... -->
                    </tbody>
                </table>
            </div>

            <!-- 分页 -->
            <div class="px-6 py-4 flex items-center justify-between border-t border-gray-200">
                <div class="flex-1 flex justify-between items-center">
                    <div>
                        <p class="text-sm text-gray-700">
                            显示第 <span class="font-medium">1</span> 到 <span class="font-medium">10</span> 条，
                            共 <span class="font-medium">97</span> 条
                        </p>
                    </div>
                    <div class="flex space-x-2">
                        <button class="px-3 py-1 border rounded-lg hover:bg-gray-50" disabled>
                            上一页
                        </button>
                        <button class="px-3 py-1 border rounded-lg bg-blue-600 text-white">
                            1
                        </button>
                        <button class="px-3 py-1 border rounded-lg hover:bg-gray-50">
                            2
                        </button>
                        <button class="px-3 py-1 border rounded-lg hover:bg-gray-50">
                            3
                        </button>
                        <button class="px-3 py-1 border rounded-lg hover:bg-gray-50">
                            下一页
                        </button>
                    </div>
                </div>
            </div>
        </div>
    </div>
</body>
</html>